﻿@model ywxt.NewsPush.Models.Doors.PageModelDoorIndex
@{
    ViewBag.Title = "遥控开门";
}

<div class="page-header">
    <h1>
        @ViewBag.Title
        <small></small>
    </h1>
</div>
<div id="ModelPage">
    <div class="list-group">
        <a href="javascript:void(0);" v-on:click="open(r)" class="list-group-item" target="_self" v-for="(r, index) in Doors" v-cloak>
            {{r.Name}}
        </a>
    </div>
</div>


@section Script{
    <script src="~/Content/libs/vue/vue.min.js"></script>
    <script src="~/Content/libs/bootbox/bootbox.min.js"></script>
    <script src="~/Scripts/common.js"></script>
    <script src="~/Scripts/Door/DoorIndex.js"></script>

    <script type="text/javascript">

        var URLs = {
            URL_GET_OPENDOOR: "@Url.Action("openDoor", "Door")"
        };

        $(document).ready(function () {
            //初始化
            vm.Doors = @Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(Model.Doors));
        });
    </script>
}